<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript" src="../js/vue.js"></script>
</head>
<body>
     <div id ='root'>
        <h1>name:{{name}}</h1>
        <h1>address:{{address}}</h1>
     </div>
</body>
    <script type="text/javascript">

        Vue.config.productionTip = false
        
      const result = new Vue({
        //el: '#root',
        data:() => {
            console.log(this)  //此时这里的this将是windows对象而不是vue对象
            return{ 
                name:'zhangsan',
                address:'beijin'  
            }
        }
      })
      console.log(result)
      // 暂停1s之后再挂载root
      setTimeout(() =>{
        result.$mount('#root')
      },1000)

    </script>

</html>